﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Data.SqlClient;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using Jungle.Code.BLL;
using Jungle.Code.Utils;
using System.Collections.Generic;
using Jungle.Code.DAL;
using Jungle.Code.Core;
using System.Text;
using System.Security.Cryptography;
using Jungle.Users;


    public partial class searchBar : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected override void OnInit(EventArgs e)
        {
            
            base.OnInit(e);
        }
        public void Search(object sender, EventArgs e)
        {
            if (txt_Search.Text != "")
            {
                string s = Server.UrlEncode(txt_Search.Text);
                Response.Redirect("ru/news.aspx?cmd=search&searchText=" + s);
            }
            else 
            {
                Response.Redirect("ru/main.aspx");
            }
        }
    }
